package com.dragon.refect.annotation;

import java.lang.annotation.Annotation;
import java.util.Arrays;

/**
 * @author dragon
 * @since 2019/12/2
 */
public class AnnotationTest {

    public static void main(String[] args) {
        Class<Student> studentClass = Student.class;
        Annotation[] annotations = studentClass.getAnnotations();
        System.out.println(Arrays.toString(annotations));
        System.out.println("===================================");
        Annotation[] declaredAnnotations = studentClass.getDeclaredAnnotations();
        System.out.println(Arrays.toString(declaredAnnotations));
    }
}
